﻿using Abp.Application.Services;
using FutureApp.Media.Dto;
using System;
using System.Threading.Tasks;

namespace FutureApp.Media
{
    /// <summary>
    /// 图片应用服务
    /// </summary>
    public interface IPictureAppService : IApplicationService
    {
        /// <summary>
        /// 获取图片
        /// </summary>
        /// <param name="id">id</param>
        /// <returns>图片信息</returns>
        Task<PictureEntityDto> GetPicture(Guid id);

        /// <summary>
        /// 获取图片
        /// </summary>
        /// <param name="md5">文件md5码</param>
        /// <returns>图片信息</returns>
        PictureEntityDto GetPictureByMd5(string md5);

        /// <summary>
        /// 是否存在图片
        /// </summary>
        /// <param name="id">id</param>
        /// <returns>返回<c>true</c>则表示存在，否则不存在</returns>
        Task<bool> IsExistPicture(Guid id);

        /// <summary>
        /// 创建图片
        /// </summary>
        /// <param name="input">参数</param>
        Task<PictureEntityDto> CreatePicture(CreatePictureInput input);
    }
}
